home *** CD-ROM | disk | FTP | other *** search
/ Multimedia Dogs / Multimedia Dogs v2.0.iso / mac / data / zsupport / XObjects / Windows / MISC_X 2.0 / MISC_X.DIR / 00001.ls next >
Encoding:
Text File  |  1995-05-09  |  1.5 KB  |  56 lines

  1. global myXobj
  2.  
  3. on startMovie
  4.   if objectp(myXobj) then
  5.     myXobj(mdispose)
  6.   end if
  7.   if the machineType < 256 then
  8.     openXLib("misc_x Xobj")
  9.     set myXobj to MISC_X(mnew)
  10.     set gBootName to myXobj(mBootName)
  11.     set gPrefsFolder to myXobj(mPrefsFolder)
  12.     set gSystemFolder to myXobj(mSystemFolder)
  13.     set gBootSpace to myXobj(mSpaceOnVol, gBootName)
  14.     put "Boot Volume:" && gBootName & RETURN & "System Folder:" && gSystemFolder & RETURN & "Preferences Folder:" && gPrefsFolder & RETURN & "Boot Volume Free Disk Space:" && gBootSpace into field "System"
  15.   else
  16.     openXLib("misc_x")
  17.     set myXobj to MISC_X(mnew)
  18.     set gBootName to myXobj(mBootName)
  19.     set gPrefsFolder to myXobj(mWindowsDirectory)
  20.     set gBootSpace to myXobj(mSpaceOnVol, gBootName)
  21.     put "Boot Volume:" && gBootName & RETURN & "Windows Directory:" && gPrefsFolder & RETURN & "Boot Volume Free Disk Space:" && gBootSpace into field "System"
  22.   end if
  23. end
  24.  
  25. on stopMovie
  26.   myXobj(mdispose)
  27.   if the machineType < 256 then
  28.     closeXLib("misc_X Xobj")
  29.   else
  30.     closeXLib("misc_x")
  31.   end if
  32. end
  33.  
  34. on closeWindow
  35.   stopMovie()
  36.   tell the stage
  37.     cleanupMIAW()
  38.   end tell
  39. end
  40.  
  41. on megabytes number
  42.   set theFP to the floatPrecision
  43.   set the floatPrecision to 2
  44.   set megs to number / 1024 / 1024
  45.   set the floatPrecision to theFP
  46.   return megs
  47. end
  48.  
  49. on gigaBytes number
  50.   set theFP to the floatPrecision
  51.   set the floatPrecision to 2
  52.   set gigs to number / 1024 / 1024 / 1024
  53.   set the floatPrecision to theFP
  54.   return(megs)
  55. end
  56.